package com.zdxlz.fcmp.upms.api.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.zdxlz.fcmp.common.mybatis.base.BaseEntity;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;

import static com.zdxlz.fcmp.common.core.constant.ParameterVerifyMsgConstants.*;

/**
 * 角色信息表(SystemRole)表实体类
 *
 * @author makejava
 * @since 2025-02-24 13:49:10
 */
@Data
@NoArgsConstructor
@EqualsAndHashCode(callSuper = true)
@TableName("system_role")
public class SystemRole extends BaseEntity {

    /**
     * 租户ID
     */
    @TableField("tenant_id")
    private Integer tenantId;

    /**
     * 角色名称
     */
    @TableField("name")
    @NotBlank(message = ROLE_NAME_VERIFY_MSG)
    private String name;
    /**
     * 角色权限字符串
     */
    @TableField("code")
    @NotBlank(message = ROLE_CODE_VERIFY_MSG)
    private String code;
    /**
     * 角色状态(true：启用 false：停用)
     */
    @TableField("status")
    @NotNull(message = ROLE_STATUS_VERIFY_MSG)
    private Boolean status;
    /**
     * 备注
     */
    @TableField("remark")
    private String remark;
}
